<template>
  <el-dialog title="预览" :visible.sync="$attrs.visableIf" @close="handleCloseDialog" :close-on-click-modal="false" :close-on-press-escape="false" append-to-body width="1000px">
    <div class="images-big">
      <img :src="imgUrl"/>
    </div>

  </el-dialog>
</template>

<script>
  export default {
    name: 'viewImg',
    props: ['imgUrl'],
    data() {
      return {
        imgType: ['png', 'jpg', 'jpeg', 'gif']
      }
    },
    created() {
      console.log('传过来的信息', this.imgInfo)
    },
    methods: {

      handleCloseDialog() {
        this.$emit('update:visableIf', false)
        this.$emit('handleCloseFilter') //关闭弹窗;
      }
    }
  }
</script>

<style scoped lang="scss">
  .images-big {
    width: 100%;
    height: 600px;
    text-align: center;

    img {
      max-width: 100%;
      height: auto;
      width: auto;
      max-height: 100%;
    }
  }

  .videoDiv {
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: 100%;
  }
</style>
